<div class="row">
  <div class="span3 bs-docs-sidebar ">
 	<*include file="<*$controller*>/location.tpl"*>
  </div>
  
  <div class="span8"> 
  <p style="color:#F00">上传图片大小为720*480</p>
<form action="/<*$controller*>/vipsave" method="post" id="form1" enctype="multipart/form-data" >    
        <table class="table table-bordered " style="margin-top:15px;">
        	<tr><th>名字</th><th>英文</th><th>图片</th><th>删除</th></tr>
        	<*foreach from=$result item=item key=key*>
            <tr>
            	<td><input type="text" name="name[]" id="name" value="<*$item.name*>" ></td>
                <td><input type="text" name="enname[]" id="enname" readonly="readonly" value="<*$item.enname*>" ></td>
                <td>
                    <*if $item.cloudpath.0*>
                        <*foreach from=$item.cloudpath item=m key=y*>
                        <img class="span1" src="http://cloud.yunxiaoche.com/images/<*$m*>.jpg"/>
                        <*/foreach*>
                    <*else*>
                    没有图片！
                    <*/if*>
                        <div class="span2" style="margin-top:5px;"><button type="button" class="btn btn-primary btn-mini" onclick="window.location='/<*$controller*>/vippicture/itemid/<*$item.itemid*>'">管理图片</button></div>
                </td>
                <td><button type="button" class="btn" onclick="deleteit('<*$item.itemid*>')">X</button></td>
				<input type="hidden" name="itemid[]" value="<*$item.itemid*>" id=""/>
            </tr>
            <*/foreach*>
        	<tr><td colspan="4" style="text-align:center;">
                <button type="submit" class="btn btn-primary" >保存修改</button>
                <button type="button" class="btn" onclick="window.location='/<*$controller*>/<*$action*>'">取消</button>
                <button type="button" class="btn" onclick="window.location='/<*$controller*>/vipadd'">增加</button>
        </table>
</form>
  </div>
</div>
<script type="text/javascript">
  function deleteit(id)
{
  if(confirm("确定要删除吗？")){
   window.location='/<*$controller*>/vipdelete/id/'+id;
  }
} 

</script> 
